#include "tcpClient.hpp"

#include <memory>

void Usage(const char* proc)
{
    std::cout << "Usage:\n\t" << proc << " server_ip server_port" << std::endl;
}

int main(int argc, char*argv[])
{
    if(argc != 3)
    {
        Usage(argv[0]);
        exit(3);
    }

    std::string serverip = argv[1];
    uint16_t serverport = atoi(argv[2]);
    std::unique_ptr<tcpClient>tcli(new tcpClient(serverip, serverport));
    tcli->initClient();
    tcli->run();

    return 0;
}